package com.shen.function;

import java.util.function.Function;

public class Demo01 {
    public static void main(String[] args) {

        /**
         * 传入一个String 返回一个Object
         */
        /*Function function = new Function<String,Object>() {
            @Override
            public Object apply(String o) {
                return o;
            }
        };*/
        Function function=(str)->{return str;};

        /**
         * 测试
         */
        System.out.println(function.apply("abcbb"));//abcbb
    }
}

